package com.example.afinal.offlineupdate.update;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
/**
 * Created by Final on 20/11/2017.
 */

public class StorageMountListener extends BroadcastReceiver{

    @Override
    public void onReceive(final Context context, Intent intent) {
        if(intent.getAction().equals(Intent.ACTION_MEDIA_MOUNTED)){
            String path = intent.getData().getPath();
            ApkUpdateUtils.getInstance().checkLocalUpdateAtBackground(context, path);
        }
    }

}
